package com.sardine.base.mybatis;

import org.slf4j.Logger;
import org.slf4j.LoggerFactory;

/**
 * 北京京东世纪贸易有限公司<br>
 * Created with IntelliJ IDEA.
 * Date:2017/2/15
 * Time:12:04
 *
 * @author daifeng<br>
 *         daifeng@imdada.cn
 * @since JDK 1.7 <br>
 * Copyright (c) 2017 imdada System Incorporated All Rights Reserved.
 */
public class PageQueryBean<T> {
    private static final Logger logger = LoggerFactory.getLogger(PageQueryBean.class);
    /**
     * 查询参数
     */
    private T item;
    /**
     * 排序的字段名称
     */
    private String sortName;// 定义哪些列可以进行排序。 null

    /**
     * 排序方式：升，降
     */
    private OrderEnum sortOrder = OrderEnum.ASC;//OrderEnum 定义列的排序顺序，只能是'asc'或'desc'。

    /**
     * 分页请求对象，用于动态mybatis
     */
    private MyBatisPageBean pageBean;

    public T getItem() {
        return item;
    }

    public void setItem(T item) {
        this.item = item;
    }

    public String getSortName() {
        return sortName;
    }

    public void setSortName(String sortName) {
        this.sortName = sortName;
    }

    public OrderEnum getSortOrder() {
        return sortOrder;
    }

    public void setSortOrder(OrderEnum sortOrder) {
        this.sortOrder = sortOrder;
    }

    public MyBatisPageBean getPageBean() {
        return pageBean;
    }

    public void setPageBean(MyBatisPageBean pageBean) {
        this.pageBean = pageBean;
    }
}
